<html>

<head>
    <meta charset="utf-8">
    <meta name="author" content="xsl">
    <script src="jquery-3.1.1.js"></script>
    <title>图片切换</title>
    <style>
        .outer{
            width: 300px;
            margin: 50px auto;
            padding: 30px auto;
        }
        h1{
            color: #444;
            text-align: center;
            font-size: 20px;
        }
        ul,li{
            padding: 0;
            margin: 0;
            list-style: none;
        }
        ul{
            width: 196px;
            height: 525px;
            border: 1px solid #ccc;
            margin: 0 auto;
            box-sizing: border-box;
            background-color: #ddd;
        }
        ul li{
            width: 180px;
            height: 150px;
            overflow: hidden;
            margin: 8px;
            position: relative;
        }
        ul li .yin{
            position: absolute;
            top: 0;
            left: 180px;
        }
        ul li .ming{
            position: relative;
            top: 0;
            left: 0;
        }
        ul li span{
            display: inline-block;
            width: 100%;
            position: absolute;
            height: 20px;
            color: white;
            font-weight: bold;
            font-size: 14px;
            text-indent: 20px;
            font-family: '微软雅黑'
        }
        .top{
            bottom: 0;
            left: 0;
        }
        .down{
            left: 0;
            bottom: -20px;
        }
    </style>
</head>

<body>
    <div class="outer">
        <hr>
        <ul>
            <h1>专辑推荐</h1>
            <li>
                <img src="img/1_1.jpg" alt="" class="ming">
                <img src="img/1_2.jpg" alt="" class="yin">
                <span class="top" style="background-color: #D45A57">COCOON/可可尼</span>
                <span class="down" style="background-color: #D25A57">几何为网/极致绚烂</span>
            </li>
            <li>
                <img src="img/2_1.jpg" alt="" class="ming">
                <img src="img/2_2.jpg" alt="" class="yin">
                <span class="top" style="background-color: #0e414b">INSUN/恩裳</span>
                <span class="down" style="background-color: #10434d">2013春印象</span>
            </li>
            <li>
                <img src="img/3_1.jpg" alt="" class="ming">
                <img src="img/3_2.jpg" alt="" class="yin">
                <span class="top" style="background-color: #1D69A6">JNBY/江南布衣</span>
                <span class="down" style="background-color: #1b6aa6">NANMENG/南梦</span>
            </li>
        </ul>
    </div>
</body>

</html>
<script>
    $('ul li').hover(function(){
        // 图片转换
          $(this).find('.yin').stop().animate({
              left:0,
          },200)
          $(this).find('.ming').stop().animate({
            left:'-180px',
        },200)
        // 文字转换
        $(this).find('.top').stop().animate({
            bottom:'-20px',   
        },200)
        $(this).find('.down').stop().animate({
            bottom:'0px',   
        },200)
    },function(){
        // 图片转换
        $(this).find('.yin').stop().animate({
            left: '180px',
        },200)
        $(this).find('.ming').stop().animate({
            left:0,
        },200)
        // 文字转换
        $(this).find('.top').stop().animate({
            bottom:'0px',   
        },200)
        $(this).find('.down').stop().animate({
            bottom:'-20px',   
        },200)
    })
</script>